//
//  LLShopGoodsModel.m
//  LoveLove
//
//  Created by 肖兰月 on 2019/4/10.
//  Copyright © 2019 wkf. All rights reserved.
//

#import "LLShopGoodsModel.h"

@implementation LLShopGoodsModel


- (NSAttributedString *)attrPrice {
    NSString *priceStr = [NSString stringWithFormat:@"¥%@ ¥%@",_goods_buy, _goods_point];
    NSMutableAttributedString *attrPrice = [[NSMutableAttributedString alloc] initWithString:priceStr];
    [attrPrice addAttributes:@{NSFontAttributeName:LLRegularFont(13),NSForegroundColorAttributeName:LLColor(222, 67, 53)} range:NSMakeRange(0, 1)];
    [attrPrice addAttributes:@{NSFontAttributeName:LLRegularFont(19),NSForegroundColorAttributeName:LLColor(222, 67, 53)} range:NSMakeRange(1, _goods_buy.length + 1)];
    [attrPrice addAttributes:@{NSStrikethroughStyleAttributeName:[NSNumber numberWithInteger:NSUnderlineStyleSingle],NSForegroundColorAttributeName:LLColorRGB(200),NSFontAttributeName:LLRegularFont(13)} range:NSMakeRange(priceStr.length-_goods_point.length-1, _goods_point.length+1)];
    return attrPrice;
}

@end
